package Chapter03.Homework;

import java.util.Scanner;

public class Test07 {
    public static void main(String[] args) {
        int ge,shi,bai,qian,sum;
        System.out.println("请输入会员号：");
        Scanner input =new Scanner(System.in);
        int vip=input.nextInt();
        ge=vip%10;
        shi=vip/10%10;
        bai=vip/100%10;
        qian=vip/1000;
        sum=ge+shi+bai+qian;
        if(sum>24){
            System.out.println("恭喜您，您中奖了，奖品是彩电一台");
        }else if(sum>20){
            System.out.println("恭喜您，您中奖了，奖品是电吹风一部");
        }else if(sum>16){
            System.out.println("恭喜您，您中奖了，奖品是餐巾纸一包");
        }else {
            System.out.println("下次继续努力");
        }
    }
}
